﻿using System;
using Newtonsoft.Json;
using ZilLion.Service.Core.Domain.EntityBase.JsonConverter;
using ZilLion.Service.WeChatMall.Domain.Requests.CrmProxy;

namespace ZilLion.Service.WeChatMall.Domain.Responses.CrmProxy
{
    public class AccCashPayResponse
    {
        public QianzhReturn QianzhReturn { get; set; }

        public Ywcore YwCore { get; set; }
        [JsonProperty("errormodel")]
        public CrmErrormodel Errormodel { get; set; }

        [JsonProperty("description")]

        public string Description { get; set; }
    }

    public class QianzhReturn
    {
        /// <summary>
        ///     本次消费：现金钱包
        /// </summary>
        public decimal Accbcxj { get; set; }

        /// <summary>
        ///     本次消费：增值钱包（不含红包）
        /// </summary>
        public decimal Accbczz { get; set; }

        /// <summary>
        ///     本次消费：红包
        /// </summary>
        public decimal Accbchb { get; set; }

        /// <summary>
        ///     最新折扣类别id
        /// </summary>
        public int Zklbid { get; set; }

        /// <summary>
        ///     最新折扣类别失效时间(读取缓存)
        /// </summary>
        [JsonConverter(typeof(ChinaDateTimeConverter))]
        public DateTime Zklbshixrq { get; set; }

        /// <summary>
        ///     余额：现金金额（充值入-累计出）
        /// </summary>
        public decimal Acccashbalance { get; set; }

        /// <summary>
        ///     余额：增值金额（充值入-累计出）（不含红包）
        /// </summary>
        public decimal Accaddbalance { get; set; }

        public int Acckzid { get; set; }

        public long RemoveHbAccid { get; set; }
    }


    public class CrmErrormodel
    {
        /// <summary>
        ///     错误类型
        /// </summary>
        public string Errtype { get; set; }

        /// <summary>
        ///     错误描述
        /// </summary>
        public string desc { get; set; }
    }
}